package com.weipai.springboot.module.controller;

import com.weipai.springboot.model.CashRecord;
import com.weipai.springboot.model.api.Response;
import com.weipai.springboot.module.service.CashRecordService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author songmengqiang
 * @create 2018-09-26 18:39
 *
 * 提现记录模块
 * **/
@RestController
public class CashRecordController {

    @Autowired
    private CashRecordService cashRecordService;

    //添加 提现记录
    @RequestMapping("/cashRecord/save")
    Response save(CashRecord cashRecord) {
        return cashRecordService.save(cashRecord);
    }

    //修改提现记录
    @RequestMapping("/cashRecord/update")
    Response update(CashRecord cashRecord) {
        return cashRecordService.update(cashRecord);
    }

    //查询员工的收益提现记录 status 提现状态	 -1:提现失败 0:待处理 1:提现成功
    @RequestMapping("/cashRecord/query")
    Response query() {
        return cashRecordService.query();
    }






}
